package work;

public class Test10 {
    public static void main(String args[]){

        String str = "world";
        String s;
        String ss = new String("world");
        switch((s = str).hashCode()){
            default:
                break;
            case 99162322:
                if(s.equals("hello"))
                    System.out.println("hello");
                break;
            case 113318802:
                if(s.equals("world"))
                    System.out.println("world");
                break;
        }
        System.out.println(str.hashCode());
        System.out.println(s.hashCode());
        System.out.println(ss.hashCode());


        /*str = "world";
        switch (str) {
            case "hello":
                System.out.println("hello");
                break;
            case "world":
                System.out.println("world");
                break;
            default:
                break;
        }*/
    }
}
